package com.mad.game.view;

import java.awt.GridLayout;

import javax.swing.JButton;

import com.mad.game.backend.GameDemo;
import com.mad.game.controller.GameExitApplicationMouseController;
import com.mad.game.controller.GameStartMouseController;

public class MainMenuWnd extends DefaultWnd{

	private static final long serialVersionUID = 1L;

	public MainMenuWnd() {
		super(GameDemo.TITLE+" - Main Menu", 300, 100);
	}
	
	@Override
	protected void init() {
		super.init();
		this.setResizable(false);
		this.setLayout(new GridLayout(2,1));
		JButton buttonStartGame = new JButton("Start game"); 
		JButton buttonExitGame = new JButton("Exit game"); 
		buttonStartGame.addActionListener(new GameStartMouseController(this)); 
		buttonExitGame.addActionListener(new GameExitApplicationMouseController(this));
		this.add(buttonStartGame);
		this.add(buttonExitGame);
		this.makeVisible();
	}
	
}
